import { createI18n } from 'vue-i18n'
import { getLocal } from '@/lib/utils'
//
import en from './locale/en'
import zh from './locale/zh_CN'
const messages = {
  en: {
    label: 'English',
    ...en,
  },
  'zh-cn': {
    label: '简体中文',
    ...zh,
  },
}
const lang = getLocal('lang') || 'zh-cn'
export default createI18n({
  legacy: false,
  locale: lang,
  fallbackLocale: 'zh-cn',
  messages,
})
